package com.itfenghuang.day01_作业;

import java.util.Scanner;

public class A01_job {
    public static void main(String[] args) {

        //    1.  什么是封装?
//                  隐藏对外的属性行为,仅对外提供公共访问的接口
//        封装的好处?
//                  a.提高代码的复用性
//                  b.让类与类之间产生关系  这种关系是多态的前提
//           2.this是什么?
//                    (1)this调用本类中的属性，也就是类中的成员变量；
//                    (2)this调用本类中的其他方法；
//                    (3)this调用本类中的其他构造方法，调用时要放在构造方法的首行。

//        4.1
        Teacher t1 = new Teacher("t001","薛之谦","男",26,"Java");
        Teacher t2 = new Teacher("t002","张碧晨","女",24,"IOS");
        Teacher t3 = new Teacher("t003","张杰","男",24,"Java");
        t1.sx();
        t2.sx();
        t3.sx();

//        4.2
        Course k1 = new Course("s001","Java","2020-02-08","包含JavaSE与JavaEE");
        Course k2 = new Course("s002","IOS","2020-02-09","JOS开发");
        k1.yy();
        k2.yy();

//    7
//        Scanner scanner = new Scanner(System.in);
//        System.out.println("学号");
//        String xh = scanner.nextLine();
//        System.out.println("姓名");
//        String xm = scanner.nextLine();
//        System.out.println("性别");
//        String xb = scanner.nextLine();
//        System.out.println("身高");
//        String sg = scanner.nextLine();
//        System.out.println("年龄");
//        int nl = scanner.nextInt();
//        Student_7 student = new Student_7(xh,xm,xb,sg,nl);
//
//        System.out.println(student.getId()+student.getName()+student.getSex()
//                +student.getHeight()+student.getAge());
        Dog dog = new Dog();
        dog.setName("xiao");     //  设置值
        String name = dog.getName();//  获取值
        System.out.println(name);   //  打印值

    }




}
